<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href='<?php echo asset_url()."customcss/custombody.css"; ?>'>

<title>AITAA&reg - View Jobs</title>

<style type="text/css">


</style>
</head>
<body>

<div id="container"><br>
<div class="col-md-8">
<!-- add filters here -->
</div>
<div class="col-md-8">
<a href="<?php echo base_url();?>index.php/career/postjob"><button type="button" class="btn btn-success">Post an Opportunity</button></a>
</div>
<br><br><br>
<table class="table table-hover">
<tr><th>ID</th><th>Title</th><th>No of Positions</th><th>Post Date</th><th>Close Date</th><th>Job Description</th><th>Posted By</th>
<th>Contact Email</th><!--<th></th><th></th> --></tr>
<?php 
	
	if(!empty($results))
	{
	foreach ($results as $row)
		{
			echo "<tr><td>".$row->jobId."</td><td>".$row->title."</td><td>".$row->vacancy."</td>
				<td>".$this->common->dateformatnormal($row->odate)."</td><td>".$this->common->dateformatnormal($row->cdate)."</td><td><a href='".base_url()."index.php/career/viewjob/".$row->jobId."'>Click Here for more</a></td><td>".$row->name."</td>";
			if(!empty($row->contact))
			{
				echo "<td>".$row->contact."</td>";
			}
			else
			{
				echo "<td>".$row->email_id."</td>";
			}
			echo "</tr>";
			//<td>".$row->mobile."</td><td>".$row->email_id."</td></tr>";
		}
	}
	else
		echo "<tr><td colspan=7>No Rows to display</td></tr>";

?>
</table>
<p class="pagination"><?php if(!empty($links)) echo $links; ?></p>
</div>
	<script src='<?php echo asset_url()."/js/bootstrap.min.js"?>'></script>
	<script src='<?php echo asset_url()."/js/jquery-1.10.2.min.js"?>'></script>
	</body>
</html>